<form id="edit-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Vip_name')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-vip_name" class="form-control" name="row[vip_name]" type="text" value="{$row.vip_name|htmlentities}">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Json')}:</label>
        <div class="col-xs-12 col-sm-8">
            
            <table class="table fieldlist" data-name="row[json]" data-template="row[json]tpl">
                <tr>
                    <td>{:__('json title')}</td>
<td>{:__('json content')}</td>
                    <td width="90">{:__('Operate')}</td>
                </tr>
                <tr><td colspan="3">
                <a href="javascript:;" class="btn btn-sm btn-success btn-append"><i class="fa fa-plus"></i> {:__('Append')}</a>
                <textarea name="row[json]" class="form-control hide" cols="30" rows="5">{$row.json|htmlentities}</textarea>
                </td></tr>
            </table>
            <script type="text/html" id="row[json]tpl">
                <tr>
                    <td><input type="text" name="<%=name%>[<%=index%>][title]" class="form-control" value="<%=row.title%>"/></td>
<td><input type="text" name="<%=name%>[<%=index%>][content]" class="form-control" value="<%=row.content%>"/></td>
                    <td width="90">
                        <span class="btn btn-sm btn-danger btn-remove"><i class="fa fa-times"></i></span>
                        <span class="btn btn-sm btn-primary btn-dragsort"><i class="fa fa-arrows"></i></span>
                    </td>
                </tr>
            </script>

        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Open_vip')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-open_vip" class="form-control" step="0.01" name="row[open_vip]" type="number" value="{$row.open_vip|htmlentities}">
        </div>
    </div>
    <div class="form-group {$row['id']==1?'':'hide'}" >
        <label class="control-label col-xs-12 col-sm-2">{:__('有效期（天）')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-validity_day" class="form-control" step="0.01" name="row[validity_day]" type="number" value="{$row.validity_day|htmlentities}">
        </div>
    </div>
    <div class="form-group layer-footer">
        <label class="control-label col-xs-12 col-sm-2"></label>
        <div class="col-xs-12 col-sm-8">
            <button type="submit" class="btn btn-primary btn-embossed disabled">{:__('OK')}</button>
            <button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
        </div>
    </div>
</form>
